import {
  req
} from '../utils/req.js';

export default {
  //附近社区
  houses(param) {
    return req.get("api/index/houses", param)
  },
  //选择社区
  selectHouse(param) {
    return req.put("api/index/selectHouse", param)
  },
  //定位选择城市
  selectGps(param) {
    return req.post("api/index/selectGps", param)
  },
  //获取用户主页内容
  UserIndex(param) {
    return req.post("api/index/index", param)
  },
  //获取用户主页下期内容
  user_next_goods(param) {
    return req.post("api/index/user_next_goods", param)
  },
  //获取首页分享
  shareInit(param) {
    return req.post("api/index/shareInit", param)
  }, 
  //获取商品
  goods_init(param) {
    return req.get("api/index/goods_init", param)
  },
  //商品详情
  goodsIndex(param) {
    return req.get("api/goods/index", param)
  },
  //商品详情Img
  getImage(param) {
    return req.post("api/Common/getImage", param)
  },
  //用户中心
  User(param) {
    return req.post("api/User/index", param)
  },
  //我的评论
  myComment(param) {
    return req.get("api/User/myComment", param)
  },
  //申请做团长
  applyCaptain(param) {
    return req.post("api/user/applyCaptain", param)
  },
  //申请成为供应商
  applySupplier(param) {
    return req.post("api/user/applySupplier", param)
  },
  //修改个人信息
  editUserinfo(param) {
    return req.put("api/user/editUserinfo", param)
  },
  //加入购物袋
  addGoods(param) {
    return req.post("api/order/addGoods", param)
  },
  //购物袋页面
  shopBagList(param) {
    return req.post("api/order/shopBagList", param)
  },
  //修改商品数量
  saveGoodsNum(param) {
    return req.put("api/order/saveGoodsNum", param)
  },
  //删除商品
  delSbgGoods(param) {
    return req.delete("api/order/delSbgGoods", param)
  },
  //商品选中取消状态
  selectShopGoods(param) {
    return req.get("api/order/selectShopGoods", param)
  },

  //确认订单(购物车)
  confirmOrder(param) {
    return req.post("api/Order/confirmOrder", param)
  },
  //确认订单(商品)
  obconfirmOrder(param) {
    return req.post("api/Order/obconfirmOrder", param)
  },
  //提交订单发起支付
  Payment(param) {
    return req.post("api/Payment/index", param)
  },
  //订单页面
  Order(param) {
    return req.post("api/Order/index", param)
  },
  //取消订单
  cancelOrder(param) {
    return req.post("api/payment/cancelOrder", param)
  },
  //物流
  postman(param) {
    return req.post("api/Order/postman", param)
  },
  //订单待评价
  wailCommentList(param) {
    return req.post("api/Order/wailCommentList", param)
  },
  //填写评价
  wailComment(param) {
    return req.post("api/Order/wailComment", param)
  },
  //订单详情
  OrderDetails(param) {
    return req.post("api/Order/getOrderInfo", param)
  },
  //发送验证码
  send_sms(param) {
    return req.get("api/common/send_sms", param)
  },
  //团长介绍/隐私政策/供应商介绍
  WebConfig(param) {
    return req.get("api/common/WebConfig", param)
  },
  //提交申请
  applyCaptain(param) {
    return req.post("api/user/applyCaptain", param)
  },
  //申请城市
  CitiesAll(param) {
    return req.post("api/common/CitiesAll", param)
  },
}